import bpy
from bpy.types import Header, Panel

import engine.initLIB.load_dll as engineLib
import ctypes



import 全局控制.Node.插座.bl_插座基类 as 插座基类







class NODE_PT_节点属性配置(bpy.types.Panel):
	bl_space_type = 'NODE_EDITOR'
	bl_region_type = 'UI'
	bl_label = "节点属性配置"

	
	@classmethod
	def poll(cls, context):
		return True

	def draw(self, context):
		layout = self.layout
		node = context.active_node
		global g_当前节点树





class PROPERTIES_HT_header(Header):
	bl_space_type = 'PROPERTIES'

	def draw(self, _context):
		layout = self.layout

		layout.template_header()



class PROPERTIES_PT_节点属性面板(Panel):
	bl_space_type = 'PROPERTIES'
	bl_region_type = 'NAVIGATION_BAR'
	bl_label = "节点属性"
	bl_options = {'HIDE_HEADER'}

	def draw(self, context):
		layout = self.layout

		view = context.space_data

		layout.scale_x = 1.4
		layout.scale_y = 1.4
		#layout.prop_tabs_enum(view, "context", icon_only=True)













classes = (
	NODE_PT_节点属性配置,
	PROPERTIES_PT_节点属性面板,
)

def register():
	#bpy.types.NodeTree.m_是否开启节点树更新 = bpy.props.StringProperty(name='是否开启节点树更新', default='')

	for c in classes:
		bpy.utils.register_class(c)
		
def unregister():
	for c in classes:
		bpy.utils.unregister_class(c)
	









